package springcloud.domain;

import lombok.AllArgsConstructor;
import lombok.Data;
import lombok.NoArgsConstructor;
import lombok.ToString;

@Data
@AllArgsConstructor
@NoArgsConstructor
@ToString
//返回前端通用字符串
public class CommonResult<T> {
    private Integer code;
    private String message;
    private T data;
    //当data无数据时返回
    public CommonResult(Integer code,String message){
        this(code,message,null);
    }
}
